<script>
	//语法：Array.reduce(fn,[data])
	
	//var arr = [1,2,3,4,5,6,7]
	//var res = arr.reduce(function(a,b){
	//	return a + b
	//},10)
	
	//console.log(res)
	
	//var  arr  = [{
	//	age:18
	//},{
	//	age:22
	//},{
	//	age:12
	//}]
	
	//var res = arr.reduce(function(a,b){
	//	return a + b.age
	//},0)
	//console.log(res)
	


</script>